<div class="auth-main">
  <div class="auth-block">
    <h1>忘记密码</h1>

    <form [formGroup]="form" (ngSubmit)="onSubmit()" class="my-validate-form">
      <div class="form-group row">
        <label class="col-sm-2 control-label">邮箱</label>
        <div class="col-sm-10">
          <input type="text" class="form-control" name="email" formControlName="email"
                 [(ngModel)]="model.email" #email>
        </div>
      </div>

      <div class="form-group row">
        <label class="col-sm-2 col-form-label"></label>
        <div class="col-sm-10">
          <button type="submit" class="btn btn-primary btn-auth" [disabled]="!form.valid">重置密码</button>
          <a routerLink="/login" class="forgot-pass">返回登录</a>
        </div>
      </div>
      <div class="form-group row">
        <label class="col-sm-2 col-form-label"></label>
        <div class="col-sm-10">
          <div class="validate-errors">
            <div class="validate-error" *ngFor="let msg of formErrors">
              <div>{{ msg }}</div>
            </div>
          </div>
        </div>
      </div>
    </form>
  </div>
</div>
